package com.ztools.pc.service.impl.information;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ztools.common.model.pc.information.TeacherClasses;
import com.ztools.pc.mapper.information.TeacherClassesMapper;
import com.ztools.pc.service.information.TeacherClassesService;
import org.springframework.stereotype.Service;

/**
 * @Author:一口香菜
 * @Date: 2023/3/17  19:10
 * @Version 1.0
 */
@Service
public class TeacherClassesServiceImpl extends ServiceImpl<TeacherClassesMapper, TeacherClasses> implements TeacherClassesService {

    @Override
    public boolean deleteTeacherClasses(TeacherClasses teacherClasses) {
        QueryWrapper<TeacherClasses> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("teacher_id", teacherClasses.getTeacherId())
                .eq("classes_id", teacherClasses.getClassesId());
        return remove(queryWrapper);
    }

}
